package cn.wolfcode.luowowo.respository;

import cn.wolfcode.luowowo.domain.Banner;
import cn.wolfcode.luowowo.domain.Destination;
import org.springframework.data.domain.PageRequest;
import org.springframework.data.mongodb.repository.MongoRepository;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * banner持久层接口
 */
@Repository
public interface BannerRespository extends MongoRepository<Banner, String> {


    /**
     * 根据 type 和 state  查询 banner
     * @param type
     * @param state
     * @param of
     * @return
     */
    List<Banner> findByTypeAndState(int type, int state, PageRequest of);
}
